<template>
  <tui-list-cell :unlined="unlined" :arrow="arrow" :arrow-color="arrowColor" @click="onclick">
    <view class="flex-row justify-between align-center">
      <text class="text-28 color-t3">{{ label }}</text>
      <view class="flex-row align-center">
        <text class="text-30 color-t1">{{ value || '' }}</text>
      </view>
    </view>
  </tui-list-cell>
</template>

<script>
export default {
  name: 'LInfoListCell',
  props: {
    label: {
      type: String,
      default: ''
    },
    value: {
      type: [String, Number],
      default: ''
    },
    // 是否有箭头
    arrow: {
      type: Boolean,
      default: false
    },
    // 箭头颜色 传值： white,gray,warning,danger
    arrowColor: {
      type: String,
      default: 'gray'
    },
    // 隐藏线条
    unlined: {
      type: Boolean,
      default: false
    },
    index: {
      type: Number,
      default: 0
    }
  },
  methods: {
    onclick() {
      this.$emit('click', {
        index: this.index
      })
    }
  }
}
</script>

<style scoped lang="scss">

</style>
